<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>Insert title here</title>
		<script src="js/jquery-3.3.1.min.js"></script>
		<script type="text/javascript">
			function test1(){
				var data = localStorage.getItem("userData"); 
				var jsonData = JSON.parse(data);
				console.info(jsonData.username);
				alert(jsonData.username);
			}
		</script>
	</head>
	<body>
		<br/><br/>
		<input type="button" onclick="test1()" value="显示localStorage的值"/>
	</body>
</html>